# @Author：silence
# @Email：792245022@qq.com
# @Date：2024/5/10 1:17

# 格式化输出
# 定义变量
name: str = "小明"
age: int = 20
weight: float = 75.5
gender: str = "男"

# % 操作符
print("个人信息：%s %d %.2f %s" % (name, age, weight, gender))

# format 方法
print("个人信息：{} {} {:.2f} {}".format(name, age, weight, gender))

# f-string
print(f"个人信息：{name} {age} {weight:.2f} {gender}")
